﻿using System;
using System.Text;

namespace IntegrationTests.Core.Resources
{
	public static class Configuration
	{
		private static readonly Random random = new Random();
		public static string GenerateUniqueLogin(string roleType = "Login")
		{
			return String.Format("{0}{1}", roleType, random.Next());
		}

		public static string GenerateUniqueName()
		{
			return String.Format("UserName{0}", random.Next());
		}

		public static string GeneratePassword()
		{
			return "123";
		}

		public static string GenerateRandomString(int length)
		{
			var result = new StringBuilder();

			while (result.Length<length)
				result.Append(Guid.NewGuid().ToString());

			return result.ToString();
		}
	}
}